{% load add_field_css debate_tags i18n team_name_for_data_entry %}

<div class="card pr-0 mr-0 m-2 position" {% if forloop.parentloop.first %}id="team-{{ team.team.id }}"{% endif %}>
  <div class="list-group list-group-flush">

    <div class="list-group-item pb-0">
      <div class="row">
        <!-- team-name class used by unknown sides switcher -->
        <div class="col mr-auto card-title pl-md-2 pl-1 {{ team.side_code }}-team-name">
          {% team_name_for_data_entry team.team use_team_code_names %}
        </div>
        <div class="col-auto card-subtitle text-muted text-right pt-2 pr-md-2 pr-1">
          <h6>{{ team.side_code }}</h6>
        </div>
      </div>
    </div>

    {% for position in team.speakers %}
      {% include "ballot/ballot_speaks.html" %}
    {% endfor %}

    <div class="list-group-item">
      <div class="row">

        <div class="col-6 mr-0 col-mr-auto pl-md-2 pl-1 btn-group">

          <button class="btn btn-outline-secondary btn-no-hover" readonly />
            {% if pref.teams_in_debate != 'bp' %}{% trans "Result" %}{% else %}{% trans "Rank" %}{% endif %}
          </button>
          <button name="{{ team.side_code }}_rank" type="text"
                  class="btn btn-secondary btn-no-hover {{ team.side_code }}_rank" readonly  />
            ?
          </button>
          <button class="btn btn-outline-secondary btn-no-hover" readonly />{% trans "Margin" %}</button>
          <button name="{{ team.side_code }}_margin" type="text"
                  class="btn btn-secondary btn-no-hover {{ team.side_code }}_margin" readonly  />
            +0
          </button>
        </div>

        <div class="col"></div>

        <div class="col-4 btn-group pr-md-2 pr-1">
          <button name="{{ team.side_code }}_total" type="text"
                  class="btn btn-block btn-secondary btn-no-hover {{ team.side_code }}_total" readonly />00</button>
        </div>

      </div>
    </div>

  </div>
</div>
